Skip to content

[Search Connectors][Serverless] Add Search Connectors UI to the Stack Management data Section#213509

Merged
YulNaumenko merged 114 commits intoelastic:mainfrom
YulNaumenko:extract-search-connectors-ui
Apr 18, 2025
Merged

[Search Connectors][Serverless] Add Search Connectors UI to the Stack Management data Section#213509
YulNaumenko merged 114 commits intoelastic:mainfrom
YulNaumenko:extract-search-connectors-ui

Conversation

@YulNaumenko
Copy link
Copy Markdown
Contributor

@YulNaumenko YulNaumenko commented Mar 7, 2025

!!MAJORITY OF THE CHANGED FILES ARE MOVED OR COPIED!!

Vision

According to the product vision we will build a new simple UI/UX in the future https://github.com/elastic/security-team/issues/11790

This PR is a first iteration on enabling Content Connectors Management UI in Serverless Kibana Stack Management.
Elastic Managed content connectors will be available only for Security and Observability projects.

Current PR scope

  1. Used initial search_connectors plugin and renamed it to content_connectors + moved from x-pack/solutions/search to x-pack/platform/plugins/shared
  2. Copy relevant connectors UI and routes from enterprise_search plugin.
  3. Introduce the new Stack Management card/navigation option under the Data section.
  4. Enabled this plugin only in Serverless for Security and Observability projects.
  5. For making PR smaller Pipelines tab was not moved. And according to Search team vision this functionality should be dropped anyway soon.
  6. Extended fleet package logic to include elastic_connectors for security and o11y serverless projects
  7. Added back search:agentless-connectors-manager task

In Stack Management navigation:
Screenshot 2025-04-15 at 3 51 43 PM

Stack Management cards:
Screenshot 2025-04-10 at 8 41 43 PM

Create Elastic Managed Connector UI (on Agentless):

Screenshot 2025-04-15 at 3 55 29 PM

Create Self Managed Connector UI:

Screenshot 2025-04-15 at 3 55 49 PM

Next steps

  • Remove duplicated code between content_connectors, enterprise_search and serverless_search
  • Extract common server libs to the shared package kbn-search-connectors

@YulNaumenko YulNaumenko self-assigned this Mar 7, 2025
@YulNaumenko YulNaumenko changed the title [Search Connectors] Extracted Search Connectors UI and Routes to a shared plugin in platform [Search Connectors][Serverless] Add Search Connectors UI to the Stack Management data Section Mar 14, 2025
@YulNaumenko YulNaumenko enabled auto-merge (squash) April 18, 2025 01:09
@elasticmachine
Copy link
Copy Markdown
Contributor

elasticmachine commented Apr 18, 2025

💚 Build Succeeded

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
contentConnectors - 404 +404
management 86 87 +1
searchConnectors 77 - -77
searchIndices 335 333 -2
securitySolutionServerless 154 155 +1
serverless 43 44 +1
serverlessObservability 10 11 +1
serverlessSearch 411 412 +1
total +330

Public APIs missing comments

Total count of every public API that lacks a comment. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats comments for more detailed information.

id before after diff
@kbn/search-connectors 3958 3977 +19
@kbn/search-shared-ui 10 8 -2
contentConnectors - 12 +12
searchConnectors 7 - -7
total +22

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
contentConnectors - 471.5KB ⚠️ +471.5KB
enterpriseSearch 1.3MB 1.3MB +116.0B
management 31.6KB 32.8KB +1.2KB
searchIndices 180.4KB 180.6KB +106.0B
searchPlayground 207.4KB 207.5KB +158.0B
serverlessSearch 343.5KB 347.6KB +4.1KB
total +477.2KB

Public APIs missing exports

Total count of every type that is part of your API that should be exported but is not. This will cause broken links in the API documentation system. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats exports for more detailed information.

id before after diff
@kbn/search-connectors 0 1 +1

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
contentConnectors - 29.2KB +29.2KB
enterpriseSearch 38.8KB 38.8KB +1.0B
searchConnectors 60.3KB - -60.3KB
securitySolutionServerless 48.3KB 48.6KB +261.0B
serverless 9.6KB 9.8KB +195.0B
serverlessObservability 13.4KB 13.6KB +260.0B
serverlessSearch 25.8KB 26.0KB +195.0B
total -30.2KB
Unknown metric groups

API count

id before after diff
@kbn/search-connectors 3958 3977 +19
@kbn/search-shared-ui 10 8 -2
contentConnectors - 12 +12
searchConnectors 7 - -7
total +22

async chunk count

id before after diff
contentConnectors - 3 +3

ESLint disabled in files

id before after diff
searchConnectors 2 - -2

ESLint disabled line counts

id before after diff
contentConnectors - 23 +23

miscellaneous assets size

id before after diff
contentConnectors - 240.4KB ⚠️ +240.4KB

Total ESLint disabled count

id before after diff
contentConnectors - 23 +23
searchConnectors 2 - -2
total +21

History

cc @YulNaumenko

@YulNaumenko YulNaumenko merged commit 221c199 into elastic:main Apr 18, 2025
9 checks passed
davismcphee pushed a commit to davismcphee/kibana that referenced this pull request Apr 22, 2025
… Management data Section (elastic#213509)

**!!MAJORITY OF THE CHANGED FILES ARE MOVED OR COPIED!!**

### Vision

According to the product vision we will build a new simple UI/UX in the
future elastic/security-team#11790

This PR is a first iteration on enabling Content Connectors Management
UI in Serverless Kibana Stack Management.
Elastic Managed content connectors will be available only for Security
and Observability projects.
### Current PR scope

1. Used initial search_connectors plugin and renamed it to
content_connectors + moved from `x-pack/solutions/search` to
`x-pack/platform/plugins/shared`
2. Copy relevant connectors UI and routes from enterprise_search plugin.
3. Introduce the new Stack Management card/navigation option under the
Data section.
4. Enabled this plugin only in Serverless for Security and Observability
projects.
5. For making PR smaller Pipelines tab was not moved. And according to
Search team vision this functionality should be dropped anyway soon.
6. Extended fleet package logic to include elastic_connectors for
security and o11y serverless projects
7. Added back `search:agentless-connectors-manager` task

In Stack Management navigation:
<img width="2062" alt="Screenshot 2025-04-15 at 3 51 43 PM"
src="https://github.com/user-attachments/assets/5c93ba01-9a6a-4eac-a21d-1370f03b8f35"
/>

Stack Management cards:
<img width="2081" alt="Screenshot 2025-04-10 at 8 41 43 PM"
src="https://github.com/user-attachments/assets/3def1c12-561b-4a84-8241-4dd61cd9313d"
/>


Create Elastic Managed Connector UI (on Agentless):

<img width="1822" alt="Screenshot 2025-04-15 at 3 55 29 PM"
src="https://github.com/user-attachments/assets/6e9fea48-85e7-43df-919d-0e5492d0e704"
/>

Create Self Managed Connector UI:

<img width="2064" alt="Screenshot 2025-04-15 at 3 55 49 PM"
src="https://github.com/user-attachments/assets/d5051898-c8fa-4e41-b9ea-b41d4ed4a0d5"
/>

### Next steps

- [ ] Remove duplicated code between content_connectors,
enterprise_search and serverless_search
- [ ] Extract [common server
libs](https://github.com/elastic/kibana/tree/main/x-pack/solutions/search/plugins/enterprise_search/server/lib)
to the shared package `kbn-search-connectors`

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Steph Milovic <stephanie.milovic@elastic.co>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: Artem Shelkovnikov <artem.shelkovnikov@elastic.co>
Co-authored-by: Artem Shelkovnikov <lavatroublebubble@gmail.com>
Co-authored-by: Kyle Pollich <kyle.pollich@elastic.co>
TattdCodeMonkey added a commit that referenced this pull request Apr 23, 2025
## Summary

Fixes bug introduced by: #213509
where serverless search & enterprise search could not load list of
available connector types from the connectors plugin. This was caused by
2 things in serverless, 1) the entire plugin was disabled and 2) the
plugin id was renamed.

Updated the `contentConnectors` plugin to have a `ui.enabled` config
value to override just disabling the management UI from being registered
for Serverless Search, while still allowing the plugin to be enabled.
And updated the usages of the `searchConnectors` plugin in
`enteprise_search` & `serverless_search` to account for it being renamed
to `contentConnectors`

Of note this bug would have been caught by FTRs, but they have been
skipped for being
[flakey](#203462) for some time,
and have proven [hard
fix](#205971) given the current UX
😔

### Checklist

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios
- [ ] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed
akowalska622 pushed a commit to akowalska622/kibana that referenced this pull request May 29, 2025
… Management data Section (elastic#213509)

**!!MAJORITY OF THE CHANGED FILES ARE MOVED OR COPIED!!**

### Vision

According to the product vision we will build a new simple UI/UX in the
future elastic/security-team#11790

This PR is a first iteration on enabling Content Connectors Management
UI in Serverless Kibana Stack Management.
Elastic Managed content connectors will be available only for Security
and Observability projects.
### Current PR scope

1. Used initial search_connectors plugin and renamed it to
content_connectors + moved from `x-pack/solutions/search` to
`x-pack/platform/plugins/shared`
2. Copy relevant connectors UI and routes from enterprise_search plugin.
3. Introduce the new Stack Management card/navigation option under the
Data section.
4. Enabled this plugin only in Serverless for Security and Observability
projects.
5. For making PR smaller Pipelines tab was not moved. And according to
Search team vision this functionality should be dropped anyway soon.
6. Extended fleet package logic to include elastic_connectors for
security and o11y serverless projects
7. Added back `search:agentless-connectors-manager` task

In Stack Management navigation:
<img width="2062" alt="Screenshot 2025-04-15 at 3 51 43 PM"
src="https://github.com/user-attachments/assets/5c93ba01-9a6a-4eac-a21d-1370f03b8f35"
/>

Stack Management cards:
<img width="2081" alt="Screenshot 2025-04-10 at 8 41 43 PM"
src="https://github.com/user-attachments/assets/3def1c12-561b-4a84-8241-4dd61cd9313d"
/>


Create Elastic Managed Connector UI (on Agentless):

<img width="1822" alt="Screenshot 2025-04-15 at 3 55 29 PM"
src="https://github.com/user-attachments/assets/6e9fea48-85e7-43df-919d-0e5492d0e704"
/>

Create Self Managed Connector UI:

<img width="2064" alt="Screenshot 2025-04-15 at 3 55 49 PM"
src="https://github.com/user-attachments/assets/d5051898-c8fa-4e41-b9ea-b41d4ed4a0d5"
/>

### Next steps

- [ ] Remove duplicated code between content_connectors,
enterprise_search and serverless_search
- [ ] Extract [common server
libs](https://github.com/elastic/kibana/tree/main/x-pack/solutions/search/plugins/enterprise_search/server/lib)
to the shared package `kbn-search-connectors`

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Steph Milovic <stephanie.milovic@elastic.co>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: Artem Shelkovnikov <artem.shelkovnikov@elastic.co>
Co-authored-by: Artem Shelkovnikov <lavatroublebubble@gmail.com>
Co-authored-by: Kyle Pollich <kyle.pollich@elastic.co>
akowalska622 pushed a commit to akowalska622/kibana that referenced this pull request May 29, 2025
## Summary

Fixes bug introduced by: elastic#213509
where serverless search & enterprise search could not load list of
available connector types from the connectors plugin. This was caused by
2 things in serverless, 1) the entire plugin was disabled and 2) the
plugin id was renamed.

Updated the `contentConnectors` plugin to have a `ui.enabled` config
value to override just disabling the management UI from being registered
for Serverless Search, while still allowing the plugin to be enabled.
And updated the usages of the `searchConnectors` plugin in
`enteprise_search` & `serverless_search` to account for it being renamed
to `contentConnectors`

Of note this bug would have been caught by FTRs, but they have been
skipped for being
[flakey](elastic#203462) for some time,
and have proven [hard
fix](elastic#205971) given the current UX
😔

### Checklist

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios
- [ ] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed
wildemat added a commit that referenced this pull request Sep 23, 2025
@elastic/kibana-management: I need your input on a display change to
index mappings that affects the mapping pages within stack management.

This is part of a larger effort to redesign and consolidate index
management between search and stack management. See [[Epic][Design]
Index Management
Improvements](elastic/search-team#9365).

## Summary
When a user has no index mappings, we'd like to show a minimalistic
prompt ([design](elastic/search-team#9737))
for field creation:

<kbd><img width="852" height="421" alt="Screenshot 2025-08-19 at 10 57
44 AM"
src="https://github.com/user-attachments/assets/6977be6a-b8e6-4389-b475-c93c32d80a8c"
/></kbd>


#### There are 4 variations of the mappings tab (screenshots below):
1. Stack Management -> Index Management
2. Stack Management -> Content Connectors
3. Search Solution -> Index Management
4. Search Solution -> Content Connectors

Within search, we'd like to just show the new empty prompt (`Add fields
to your data...`) and hide the extra context items (`About index
mappings...` and `Transform your searchable content`).

I'd like to know if @elastic/kibana-management would like the same
treatment, or if I should update this PR to only apply the empty state
to search solution.

We can also try a variation where the right-hand context items do not
display in the empty state, but show up again when fields are added.

The current state of this PR shows the empty state on every mappings
tab, alongside whatever extra context items are already there.

There is duplicated code across these various mappings displays. (see
#213509 for example). This PR isn't meant to solve that. However I think
if we agree on a single version to show, it'll make that task easier.

## Changes
* Leverage `EuiEmptyPrompt` to display a CTA to add a field
* During field creation, if they have no saved fields yet, hide the
"filter" bar and "list/json" buttons. Those don't provide helpful
context until after fields exist.
* Provide a link to mapping documentation
* Added a few unit tests to verify the proper show/hide behavior of the
empty prompt


## Screenshots

### Sample interaction:


https://github.com/user-attachments/assets/03015f96-9b9d-404d-843b-02b5dfb78f4a


### Stack Management Index Management:
#### path:
`app/management/data/index_management/indices/index_details?indexName={indexName}&tab=mappings`

<kbd>
<img width="1487" height="815" alt="stack classic mgmt indexmgmt"
src="https://github.com/user-attachments/assets/0808495f-4454-4fd9-9b38-92526899d936"
/>

</kbd>

### Stack Management Content Connectors:
#### path:
`app/management/data/content_connectors/connectors/{connectorID}/index_mappings`

<kbd>
<img width="1442" height="852" alt="stack classic mgmt connectors"
src="https://github.com/user-attachments/assets/84ac974d-cfaa-45b5-82cd-69ce6ba2b4d0"
/>

</kbd>

### Search Solution Index Management:
#### path:
`search/app/elasticsearch/indices/index_details/{indexName}/mappings`

<kbd>
<img width="1492" height="687" alt="stack search indices"
src="https://github.com/user-attachments/assets/07651902-d7e7-4455-b536-f3c2ac11a72e"
/>

</kbd>

### Search Solution Content Connectors:
#### path:
`search/app/elasticsearch/content/connectors/{connectorID}/index_mappings`

<kbd>
<img width="1476" height="789" alt="stack search connectors entsearch"
src="https://github.com/user-attachments/assets/90a1aa5a-d19c-45f9-ade5-ce85507aef52"
/>

</kbd>


## Tests

```bash
➜  kibana git:(search/indices/mappings/empty-state) ✗ yarn test:jest \
'x-pack/platform/plugins/shared/index_management/__jest__/client_integration/index_details_page/index_details_page.test.tsx' \
-t '\<IndexDetailsPage /\> Mappings tab' \
-c './x-pack/platform/plugins/shared/index_management/jest.config.js' \
--verbose=false

yarn run v1.22.22

 PASS  x-pack/platform/plugins/shared/index_management/__jest__/client_integration/index_details_page/index_details_page.test.tsx (14.015 s)

Test Suites: 1 passed, 1 total
Tests:       63 skipped, 25 passed, 88 total
Snapshots:   0 total
Time:        14.332 s, estimated 15 s
Ran all test suites matching /x-pack\/platform\/plugins\/shared\/index_management\/__jest__\/client_integration\/index_details_page\/index_details_page.test.tsx/i with tests matching "\<IndexDetailsPage /\> Mappings tab".
 debg CIStatsReporter committerHash: 85e34139f9a5740b9cd7
✨  Done in 17.15s.
```

Closes elastic/search-team#9737

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
CAWilson94 pushed a commit to CAWilson94/kibana that referenced this pull request Sep 24, 2025
@elastic/kibana-management: I need your input on a display change to
index mappings that affects the mapping pages within stack management.

This is part of a larger effort to redesign and consolidate index
management between search and stack management. See [[Epic][Design]
Index Management
Improvements](elastic/search-team#9365).

## Summary
When a user has no index mappings, we'd like to show a minimalistic
prompt ([design](elastic/search-team#9737))
for field creation:

<kbd><img width="852" height="421" alt="Screenshot 2025-08-19 at 10 57
44 AM"
src="https://github.com/user-attachments/assets/6977be6a-b8e6-4389-b475-c93c32d80a8c"
/></kbd>


#### There are 4 variations of the mappings tab (screenshots below):
1. Stack Management -> Index Management
2. Stack Management -> Content Connectors
3. Search Solution -> Index Management
4. Search Solution -> Content Connectors

Within search, we'd like to just show the new empty prompt (`Add fields
to your data...`) and hide the extra context items (`About index
mappings...` and `Transform your searchable content`).

I'd like to know if @elastic/kibana-management would like the same
treatment, or if I should update this PR to only apply the empty state
to search solution.

We can also try a variation where the right-hand context items do not
display in the empty state, but show up again when fields are added.

The current state of this PR shows the empty state on every mappings
tab, alongside whatever extra context items are already there.

There is duplicated code across these various mappings displays. (see
elastic#213509 for example). This PR isn't meant to solve that. However I think
if we agree on a single version to show, it'll make that task easier.

## Changes
* Leverage `EuiEmptyPrompt` to display a CTA to add a field
* During field creation, if they have no saved fields yet, hide the
"filter" bar and "list/json" buttons. Those don't provide helpful
context until after fields exist.
* Provide a link to mapping documentation
* Added a few unit tests to verify the proper show/hide behavior of the
empty prompt


## Screenshots

### Sample interaction:


https://github.com/user-attachments/assets/03015f96-9b9d-404d-843b-02b5dfb78f4a


### Stack Management Index Management:
#### path:
`app/management/data/index_management/indices/index_details?indexName={indexName}&tab=mappings`

<kbd>
<img width="1487" height="815" alt="stack classic mgmt indexmgmt"
src="https://github.com/user-attachments/assets/0808495f-4454-4fd9-9b38-92526899d936"
/>

</kbd>

### Stack Management Content Connectors:
#### path:
`app/management/data/content_connectors/connectors/{connectorID}/index_mappings`

<kbd>
<img width="1442" height="852" alt="stack classic mgmt connectors"
src="https://github.com/user-attachments/assets/84ac974d-cfaa-45b5-82cd-69ce6ba2b4d0"
/>

</kbd>

### Search Solution Index Management:
#### path:
`search/app/elasticsearch/indices/index_details/{indexName}/mappings`

<kbd>
<img width="1492" height="687" alt="stack search indices"
src="https://github.com/user-attachments/assets/07651902-d7e7-4455-b536-f3c2ac11a72e"
/>

</kbd>

### Search Solution Content Connectors:
#### path:
`search/app/elasticsearch/content/connectors/{connectorID}/index_mappings`

<kbd>
<img width="1476" height="789" alt="stack search connectors entsearch"
src="https://github.com/user-attachments/assets/90a1aa5a-d19c-45f9-ade5-ce85507aef52"
/>

</kbd>


## Tests

```bash
➜  kibana git:(search/indices/mappings/empty-state) ✗ yarn test:jest \
'x-pack/platform/plugins/shared/index_management/__jest__/client_integration/index_details_page/index_details_page.test.tsx' \
-t '\<IndexDetailsPage /\> Mappings tab' \
-c './x-pack/platform/plugins/shared/index_management/jest.config.js' \
--verbose=false

yarn run v1.22.22

 PASS  x-pack/platform/plugins/shared/index_management/__jest__/client_integration/index_details_page/index_details_page.test.tsx (14.015 s)

Test Suites: 1 passed, 1 total
Tests:       63 skipped, 25 passed, 88 total
Snapshots:   0 total
Time:        14.332 s, estimated 15 s
Ran all test suites matching /x-pack\/platform\/plugins\/shared\/index_management\/__jest__\/client_integration\/index_details_page\/index_details_page.test.tsx/i with tests matching "\<IndexDetailsPage /\> Mappings tab".
 debg CIStatsReporter committerHash: 85e34139f9a5740b9cd7
✨  Done in 17.15s.
```

Closes elastic/search-team#9737

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
niros1 pushed a commit that referenced this pull request Sep 30, 2025
@elastic/kibana-management: I need your input on a display change to
index mappings that affects the mapping pages within stack management.

This is part of a larger effort to redesign and consolidate index
management between search and stack management. See [[Epic][Design]
Index Management
Improvements](elastic/search-team#9365).

## Summary
When a user has no index mappings, we'd like to show a minimalistic
prompt ([design](elastic/search-team#9737))
for field creation:

<kbd><img width="852" height="421" alt="Screenshot 2025-08-19 at 10 57
44 AM"
src="https://github.com/user-attachments/assets/6977be6a-b8e6-4389-b475-c93c32d80a8c"
/></kbd>


#### There are 4 variations of the mappings tab (screenshots below):
1. Stack Management -> Index Management
2. Stack Management -> Content Connectors
3. Search Solution -> Index Management
4. Search Solution -> Content Connectors

Within search, we'd like to just show the new empty prompt (`Add fields
to your data...`) and hide the extra context items (`About index
mappings...` and `Transform your searchable content`).

I'd like to know if @elastic/kibana-management would like the same
treatment, or if I should update this PR to only apply the empty state
to search solution.

We can also try a variation where the right-hand context items do not
display in the empty state, but show up again when fields are added.

The current state of this PR shows the empty state on every mappings
tab, alongside whatever extra context items are already there.

There is duplicated code across these various mappings displays. (see
#213509 for example). This PR isn't meant to solve that. However I think
if we agree on a single version to show, it'll make that task easier.

## Changes
* Leverage `EuiEmptyPrompt` to display a CTA to add a field
* During field creation, if they have no saved fields yet, hide the
"filter" bar and "list/json" buttons. Those don't provide helpful
context until after fields exist.
* Provide a link to mapping documentation
* Added a few unit tests to verify the proper show/hide behavior of the
empty prompt


## Screenshots

### Sample interaction:


https://github.com/user-attachments/assets/03015f96-9b9d-404d-843b-02b5dfb78f4a


### Stack Management Index Management:
#### path:
`app/management/data/index_management/indices/index_details?indexName={indexName}&tab=mappings`

<kbd>
<img width="1487" height="815" alt="stack classic mgmt indexmgmt"
src="https://github.com/user-attachments/assets/0808495f-4454-4fd9-9b38-92526899d936"
/>

</kbd>

### Stack Management Content Connectors:
#### path:
`app/management/data/content_connectors/connectors/{connectorID}/index_mappings`

<kbd>
<img width="1442" height="852" alt="stack classic mgmt connectors"
src="https://github.com/user-attachments/assets/84ac974d-cfaa-45b5-82cd-69ce6ba2b4d0"
/>

</kbd>

### Search Solution Index Management:
#### path:
`search/app/elasticsearch/indices/index_details/{indexName}/mappings`

<kbd>
<img width="1492" height="687" alt="stack search indices"
src="https://github.com/user-attachments/assets/07651902-d7e7-4455-b536-f3c2ac11a72e"
/>

</kbd>

### Search Solution Content Connectors:
#### path:
`search/app/elasticsearch/content/connectors/{connectorID}/index_mappings`

<kbd>
<img width="1476" height="789" alt="stack search connectors entsearch"
src="https://github.com/user-attachments/assets/90a1aa5a-d19c-45f9-ade5-ce85507aef52"
/>

</kbd>


## Tests

```bash
➜  kibana git:(search/indices/mappings/empty-state) ✗ yarn test:jest \
'x-pack/platform/plugins/shared/index_management/__jest__/client_integration/index_details_page/index_details_page.test.tsx' \
-t '\<IndexDetailsPage /\> Mappings tab' \
-c './x-pack/platform/plugins/shared/index_management/jest.config.js' \
--verbose=false

yarn run v1.22.22

 PASS  x-pack/platform/plugins/shared/index_management/__jest__/client_integration/index_details_page/index_details_page.test.tsx (14.015 s)

Test Suites: 1 passed, 1 total
Tests:       63 skipped, 25 passed, 88 total
Snapshots:   0 total
Time:        14.332 s, estimated 15 s
Ran all test suites matching /x-pack\/platform\/plugins\/shared\/index_management\/__jest__\/client_integration\/index_details_page\/index_details_page.test.tsx/i with tests matching "\<IndexDetailsPage /\> Mappings tab".
 debg CIStatsReporter committerHash: 85e34139f9a5740b9cd7
✨  Done in 17.15s.
```

Closes elastic/search-team#9737

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
rylnd pushed a commit to rylnd/kibana that referenced this pull request Oct 17, 2025
@elastic/kibana-management: I need your input on a display change to
index mappings that affects the mapping pages within stack management.

This is part of a larger effort to redesign and consolidate index
management between search and stack management. See [[Epic][Design]
Index Management
Improvements](elastic/search-team#9365).

## Summary
When a user has no index mappings, we'd like to show a minimalistic
prompt ([design](elastic/search-team#9737))
for field creation:

<kbd><img width="852" height="421" alt="Screenshot 2025-08-19 at 10 57
44 AM"
src="https://github.com/user-attachments/assets/6977be6a-b8e6-4389-b475-c93c32d80a8c"
/></kbd>


#### There are 4 variations of the mappings tab (screenshots below):
1. Stack Management -> Index Management
2. Stack Management -> Content Connectors
3. Search Solution -> Index Management
4. Search Solution -> Content Connectors

Within search, we'd like to just show the new empty prompt (`Add fields
to your data...`) and hide the extra context items (`About index
mappings...` and `Transform your searchable content`).

I'd like to know if @elastic/kibana-management would like the same
treatment, or if I should update this PR to only apply the empty state
to search solution.

We can also try a variation where the right-hand context items do not
display in the empty state, but show up again when fields are added.

The current state of this PR shows the empty state on every mappings
tab, alongside whatever extra context items are already there.

There is duplicated code across these various mappings displays. (see
elastic#213509 for example). This PR isn't meant to solve that. However I think
if we agree on a single version to show, it'll make that task easier.

## Changes
* Leverage `EuiEmptyPrompt` to display a CTA to add a field
* During field creation, if they have no saved fields yet, hide the
"filter" bar and "list/json" buttons. Those don't provide helpful
context until after fields exist.
* Provide a link to mapping documentation
* Added a few unit tests to verify the proper show/hide behavior of the
empty prompt


## Screenshots

### Sample interaction:


https://github.com/user-attachments/assets/03015f96-9b9d-404d-843b-02b5dfb78f4a


### Stack Management Index Management:
#### path:
`app/management/data/index_management/indices/index_details?indexName={indexName}&tab=mappings`

<kbd>
<img width="1487" height="815" alt="stack classic mgmt indexmgmt"
src="https://github.com/user-attachments/assets/0808495f-4454-4fd9-9b38-92526899d936"
/>

</kbd>

### Stack Management Content Connectors:
#### path:
`app/management/data/content_connectors/connectors/{connectorID}/index_mappings`

<kbd>
<img width="1442" height="852" alt="stack classic mgmt connectors"
src="https://github.com/user-attachments/assets/84ac974d-cfaa-45b5-82cd-69ce6ba2b4d0"
/>

</kbd>

### Search Solution Index Management:
#### path:
`search/app/elasticsearch/indices/index_details/{indexName}/mappings`

<kbd>
<img width="1492" height="687" alt="stack search indices"
src="https://github.com/user-attachments/assets/07651902-d7e7-4455-b536-f3c2ac11a72e"
/>

</kbd>

### Search Solution Content Connectors:
#### path:
`search/app/elasticsearch/content/connectors/{connectorID}/index_mappings`

<kbd>
<img width="1476" height="789" alt="stack search connectors entsearch"
src="https://github.com/user-attachments/assets/90a1aa5a-d19c-45f9-ade5-ce85507aef52"
/>

</kbd>


## Tests

```bash
➜  kibana git:(search/indices/mappings/empty-state) ✗ yarn test:jest \
'x-pack/platform/plugins/shared/index_management/__jest__/client_integration/index_details_page/index_details_page.test.tsx' \
-t '\<IndexDetailsPage /\> Mappings tab' \
-c './x-pack/platform/plugins/shared/index_management/jest.config.js' \
--verbose=false

yarn run v1.22.22

 PASS  x-pack/platform/plugins/shared/index_management/__jest__/client_integration/index_details_page/index_details_page.test.tsx (14.015 s)

Test Suites: 1 passed, 1 total
Tests:       63 skipped, 25 passed, 88 total
Snapshots:   0 total
Time:        14.332 s, estimated 15 s
Ran all test suites matching /x-pack\/platform\/plugins\/shared\/index_management\/__jest__\/client_integration\/index_details_page\/index_details_page.test.tsx/i with tests matching "\<IndexDetailsPage /\> Mappings tab".
 debg CIStatsReporter committerHash: 85e34139f9a5740b9cd7
✨  Done in 17.15s.
```

Closes elastic/search-team#9737

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:skip This PR does not require backporting ci:build-cloud-image ci:build-serverless-image ci:cloud-redeploy Always create a new Cloud deployment ci:project-deploy-observability Create an Observability project ci:project-deploy-security Create a Security Serverless Project release_note:skip Skip the PR/issue when compiling release notes Team:Fleet Team label for Observability Data Collection Fleet team v9.1.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.